﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp;
using Volo.Abp.Domain.Entities.Auditing;

namespace PHMEE
{
    /// <summary>
    /// 轴承库厂商
    /// </summary>
    public class BearFactory : FullAuditedAggregateRoot<int>
    {
        protected BearFactory()
        {

        }

        public BearFactory(string name)
        {
            Name = name;
        }

        /// <summary>
        /// 厂商名称
        /// </summary>
        public string Name { get; private set; }

        public ICollection<BearLib> BearLibs { get; set; } = new List<BearLib>();

        public BearFactory SetName(string name)
        {
            Name = Check.NotNullOrEmpty(name, nameof(name), BearConst.MaxFactoryNameLength);
            return this;
        }
    }
}
